package cloud.simple;

import org.apache.log4j.PropertyConfigurator;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.core.env.PropertiesPropertySource;

@SpringBootApplication
public class Log4jApplication {
	
//	static{
//		try {
//			//初始化log4j
//			String log4jPath = Log4jApplication.class.getClassLoader().getResource("").getPath()+"log4j.properties";
//			System.out.println("初始化log4j......");
//			System.out.println("path is"+log4jPath);
//			PropertyConfigurator.configure(log4jPath);
//		} catch (Exception e) {
//			e.printStackTrace();
//		}
//	}
	
	public static void main(String[] args) {
		SpringApplication.run(Log4jApplication.class,args);
	}
}
